//
//  Controller.h
//  Broadcaster
//
//  Created by Blagovest Dachev on 2/1/09.
//  Copyright 2009 __MyCompanyName__. All rights reserved.
//

#import <Cocoa/Cocoa.h>
#import <SystemConfiguration/SCNetwork.h>

#import "Messanger.h"

#import "AppleRemote.h"
#import "KeyspanFrontRowControl.h"
#import "GlobalKeyboardDevice.h"
#import "RemoteControlContainer.h"
#import "MultiClickRemoteBehavior.h"


@interface Controller : NSObject {
    NSStatusItem *statusItem;
    NSImage * menuIconOn;
    NSImage * menuIconOff;
    IBOutlet NSMenu * theMenu;
	IBOutlet NSMenuItem * connectItem;
    IBOutlet NSWindow * about;
    IBOutlet NSWindow * settings;
    IBOutlet NSTextField * sJIDField;
    IBOutlet NSTextField * dJIDField;
    IBOutlet NSSecureTextField * passwordField;
    IBOutlet NSTextField * statusField;
    IBOutlet NSButton * saveButton;
	
	NSUserDefaults * prefs;
	Messanger *messanger;
	MultiClickRemoteBehavior * remoteControlBehavior;
	RemoteControlContainer* container;
}

-(IBAction)respondConnect:(id)sender;
-(IBAction)respondShowSettings:(id)sender;
-(IBAction)respondShowAbout:(id)sender;
-(IBAction)respondQuit:(id)sender;
-(IBAction)respondSave:(id)sender;

-(void)start;
-(void)stop;
-(void)connect;
-(void)disconnect;

-(BOOL)isOnline;
-(BOOL)isConnected;
-(BOOL)isAuthenticated;
-(BOOL)isXMPPReady;

@end
